-- for LOCKS and KEYS
require "map/lockandkey"

local LOCKS = GLOBAL.LOCKS
local KEYS  = GLOBAL.KEYS
local LOCKS_ARRAY = GLOBAL.LOCKS_ARRAY
local KEYS_ARRAY  = GLOBAL.KEYS_ARRAY


-- RG specific
for i = 1, 9 do
	table.insert(LOCKS_ARRAY, "RG_LINK"..i)
	table.insert(KEYS_ARRAY, "RG_LINK"..i)
end

for i,v in ipairs(LOCKS_ARRAY)do
	LOCKS[v] = i
end

for i,v in ipairs(KEYS_ARRAY)do
	KEYS[v] = i
end

for i = 1, 9 do
	LOCKS_KEYS[LOCKS["RG_LINK"..i]] = {
		KEYS["RG_LINK"..i],
		KEYS["RG_LINK"..(i+1)], -- nil for i = 9
	}
end
